#include unistd.h>
void _exit(int ret); Exit the current process without cleaning up. (This is a Pterm())
int access(const char &sstarf#star;fname, int mode); Check, if file fname is accessable with mode mode.
unsigned int alarm(unsigned int sec); Instructs the alarm clock of the calling process to send the signal SIGALRM to the calling process after sec seconds
int chdir(const char &sstarf#star;dname); Chane the current working directory to dname including drive specification.
int chmod(const char &sstarf#star;fname, int mode); Change permissions of file fname to mode.
int chown(const char &sstarf#star;fname, int uid, int gid); Change owner and group of file fname. (Fake for now)
int close(int fd); Close the file assosiated with file descriptor fd.
int creat(const char &sstarf#star;fname, unsigned mode); Create the file fname with mode mode.
int dup(int fd); Duplicate filedescriptor fd.
int dup2(int fd1, int fd2); Duplicate filedescriptor fd1 to fd2.
int execl(char &sstarf#star;path, …); int execle(char &sstarf#star;path, …, char &sstarf#star;&sstarf#star;envp); int execlp(char &sstarf#star;path, …); Execute a new process from path after a fork(), execlp use the PATH environment.
int execv(char &sstarf#star;path, char &sstarf#star;&sstarf#star;argv); int execvp(char &sstarf#star;path, char &sstarf#star;&sstarf#star;argv); int execve(char &sstarf#star;path, char &sstarf#star;&sstarf#star;argv, char &sstarf#star;&sstarf#star;envp); Execute a new process from path after a fork(), using the argv method. execvp use the PATH environment.
int fork(); int vfork(); Simulate a non multitasking fork. vfork shares data + stack with parent.
char &sstarf#star;getcwd(char &sstarf#star;buf, int size); char &sstarf#star;getwd(char &sstarf#star;buf); Get the current working directory.
unsigned short getgid(); unsigned short getuid(); Get user and group id's. (Fake for now, returning alsways root).
unsigned short getegid(); unsigned short geteuid(); Get effective user and group id's.
int getgroups(int setlen, gid_t &sstarf#star;gidset); Retrieves the current group access list of the user process and stores it in gidset.
char &sstarf#star;getlogin(); Return the user's login name. (Password file and environment are seached in order).
int getopt(int argc, const char &sstarf#star;&sstarf#star;argv, const char &sstarf#star;opt); Extract the command line options described by opt from argv.
int getpagesize (void); Get system page size
char /*getpass(char *prompt);
int getpgrp(); int setpgrp(); Get or create a process group (This basically a fake; both return getpid()).
int getpid(); int getppid(); int setpgid (pid_t pid, pid_t pgid); Return a process id for the currently running process (or the parent process) (from the basepage).
char &sstarf#star;initstate(unsigned seed, char &sstarf#star;arg_state, int n); Initialize state array of generator for random.
int isatty(int fd); Check, if fd is associated with a terminal (screen).
int link(const char &sstarf#star;old , const char &sstarf#star;new); Make a new link from new to old. Always fails.
long lseek(int fd, long pos, int whence); Set the current file posistion to position pos relative to whence.
int mkdir(const char &sstarf#star;dname, unsigned mode); Make a directory with name dname and change its mode to mode.
char &sstarf#star;mktemp(char &sstarf#star;pattern); Return a filename for a temporary file, build after pattern.
int open(const char &sstarf#star;fname, int mode, …); Open the file fname with mode mode.
long pathconf (const char &sstarf#star;path, int name); Get configurable pathname variables.
=The following table lists the possible values for name.
nameMeaning
int pause (void); Suspends the calling process until it receives a signal.
int pipe (int &sstarf#star;fildes); Creates a pipe and returns two file descriptors. Fildes[0] for reading, fildes[1] for writing.
void psignal(int signal, const char &sstarf#star;prefix); Print a error message describing the signal with a user comment.
long random(); Return a pseudo random number in the range from 0 to 231 - 1.
int rmdir(const char &sstarf#star;dname); Remove the directory with name dname.
int read(int fd, void &sstarf#star;buf, unsigned cnt); long _read(int fd, void &sstarf#star;buf, unsigned long cnt); Read cnt bytes from file descriptor fd into buffer buf.
int readlink (char &sstarf#star;filenam, char &sstarf#star;linkto, int siz); Read value of a symbolic link
void &sstarf#star;sbrk(unsigned long size); void &sstarf#star;lsbrk(long size); Emulation of the U&sstarf#star;ix sbrk() system call.
void setlinebuf(void &sstarf#star;fp); Change the buffering on stream fp from block/unbuffered to line buffered.
int setgid(int gid); int setuid(int uid); Set the real group or user id.
int setegid(int gid); int seteuid(int uid); Set the effective group or user id.
int setregid (int rgid, int egid); int setreuid (int ruid, int euid); Set real and effective group or user id.
int setsid (void); Create session and set process group ids
char &sstarf#star;setstate(char &sstarf#star;arg_state); Switch state of generator for random.
void sigpause(long mask); Suspends the calling process until it receives a signal.
int sleep(int n); Sleep for n number of seconds.
int srandom(unsigned int x); Seed generator for random.
int stime(long &sstarf#star;time); Set the current time to time in U&sstarf#star;ix format.
int symlink (char &sstarf#star;oldname, char &sstarf#star;newname); Make symbolic link to a file
long sysconf (int name); Get configurable system variables.
=The following table lists the possible values for name.
nameMeaning
long tell(int fd); Get the current file position of the file associated with fd.
int times(struct tms &sstarf#star;buf); Get process times into buf.
char &sstarf#star;ttyname(int file);
int umask(int mode); Set access mask. (Fake for now)
int unlink(const char &sstarf#star;fname); Remove the file with name fname.
void usleep(unsigned long n); Sleep for n number of milliseconds.
int utime(const char &sstarf#star;fname, const struct utimbuf &sstarf#star;ftime); Set the modification time and date of file fname to ftime.
int write(int fd, const void &sstarf#star;buf, unsigned cnt); long _write(int fd, const void &sstarf#star;buf, unsigned long cnt); Write cnt bytes from buffer buf to file descriptor fd.
int wait(int &sstarf#star;exit_code); Wait for child process.